<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .pro {
            width: 500px;
            height: 20px;
            border-radius: 20px;
            /* animation: progress 10s linear forwards; */
        }

        .pro::after {
            content: '';
            display: block;
            width: 0;
            height: 100%;
            border-radius: 20px;
            background: linear-gradient(#d3e109 50%, #09c413, 50%);
            animation: progress 3s;
        }

        @keyframes progress {
            0% {
                width: 0;
                background-color: #fff;
            }

            40% {
                width: 40%;
                background: linear-gradient(#d5dc06 20%, #22a324 10%, #d8550e 60%);

            }

            80% {
                width: 80%;
                background-color: #ce11e0;
            }

            100% {
                width: 100%;
                background-color: #d11919;
            }
        }
    </style>
</head>

<body>
    <div class="progress">
        <div class="pro"></div>
    </div>
</body>

</html>